﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace FrogEngine
{
	/// <summary>
	/// Represents a connected graph with edge weights represented as System.Double
	/// </summary>
	/// <typeparam name="K">Coordinate</typeparam>
	/// <typeparam name="V">Value for node</typeparam>
	public interface IGraph<K, V>
	{
		ISet<IGraphVertex<K, V>> Vertices { get; }
		IList<IGraphEdge<K, V>> Edges { get; }

		IGraphVertex<K, V> BFS(V value);
		IGraphVertex<K, V> BFS(K key);
		IGraphVertex<K, V> DFS(V value);
		IGraphVertex<K, V> DFS(K key);
		IEnumerable<IGraphVertex<K, V>> ShortestPath(IGraphVertex<K, V> start, IGraphVertex<K, V> end);
		IGraph<K, V> MinimumSpanningTree();
		IEnumerable<IGraphVertex<K, V>> AStar(IGraphVertex<K, V> start, IGraphVertex<K, V> end, Heuristic<IGraphVertex<K, V>, double> h);
	}
}
